<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('配置名称')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-name" data-rule="required" class="form-control" name="row[name]" type="text" value="">
        </div>
    </div>
    
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('存储类型')}:</label>
        <div class="col-xs-12 col-sm-8">
            <select id="c-type" class="form-control selectpicker" name="row[type]" data-rule="required">
                <option value="">{:__('请选择存储类型')}</option>
                {foreach name="typeList" item="vo" key="key"}
                <option value="{$key}">{$vo}</option>
                {/foreach}
            </select>
        </div>
    </div>
    
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('状态')}:</label>
        <div class="col-xs-12 col-sm-8">
            {:build_radios('row[status]', ['0'=>__('禁用'), '1'=>__('启用')])}
        </div>
    </div>
    
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('是否默认')}:</label>
        <div class="col-xs-12 col-sm-8">
            {:build_radios('row[is_default]', ['0'=>__('否'), '1'=>__('是')])}
        </div>
    </div>
    
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('备注')}:</label>
        <div class="col-xs-12 col-sm-8">
            <textarea id="c-remark" class="form-control" name="row[remark]" rows="3"></textarea>
        </div>
    </div>
    
    <!-- 配置信息区域 -->
    <div id="config-area" style="display: none;">
        <div class="form-group">
            <label class="control-label col-xs-12 col-sm-2">{:__('配置信息')}:</label>
            <div class="col-xs-12 col-sm-8">
                <div id="config-fields"></div>
            </div>
        </div>
    </div>
    
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
